package com.example.jazztalk.service;

import com.ibm.team.repository.common.TeamRepositoryException;
import com.ibm.team.repository.common.UUID;
import com.ibm.team.repository.service.AbstractRepositoryComponentInitializer;
import com.ibm.team.repository.service.IRepositoryInitializerContext;

import example.jazztalk.common.model.Message;

public class JazzTalkInitializer extends AbstractRepositoryComponentInitializer {
   public void initializeNewRepository(
         IRepositoryInitializerContext initializerContext)
         throws TeamRepositoryException {
      UUID uuid = UUID.generate();
      Message message = (Message) JazzTalkService.getMessageItemType().createItem();
      message.setText("First Post!");
      initializerContext.addNewSimpleItem(message, uuid);
   }
}
